﻿Public Class Fruit
    Public Function nuevaPosicionFruta() As Point
        Dim rnd As New Random
        Dim x, y As Integer
        Do
            x = rnd.Next(0, 135)
            y = rnd.Next(0, 245)
        Loop While x Mod 10 <> 0 Or y Mod 10 <> 0
        Dim localizacion As New Point(x, y)
        Return localizacion
    End Function
    Public Function crearFruta(ByVal snake As Point, ByVal fruit As Point) As Point
        fruit = Me.nuevaPosicionFruta
        Return fruit
    End Function

    Public Sub SumarPuntos()
        puntosTotales = puntosTotales + 10
    End Sub
End Class
